#define _CRT_SECURE_NO_WARNINGS 1
#include "List.h"


void test()
{
	ListNode* pList = ListInit();

	 ListPushBack(pList, 1);
	 ListPushBack(pList, 2);
	 ListPushBack(pList, 3);
	 ListPushBack(pList, 4);
	 ListPrint(pList);

	 ListPushFront(pList, 11);
	 ListPushFront(pList, 12);
	 ListPushFront(pList, 13);
	 ListPushFront(pList, 14);
	 ListPrint(pList);

	 ListPopFront(pList);
	 ListPopFront(pList);
	 ListPopFront(pList);
	 ListPopFront(pList);
	 ListPrint(pList);


	 ListNode* pos = ListFind(pList, 3);
	 if (pos)
	 {
		 ListErase(pos);
	 }
	 ListPrint(pList);
	 ListDestory(pList);
	 pList = NULL;
}


int main()
{
	test();
	return 0;
}
